<template>
	<view style="padding: 30rpx;">
		<view class="news-info-view">
			<view class="title">{{detail.title}}</view>
			<view class="mb-2" style="font-size: 13px; color: #999999;">{{detail.update_time}}</view>
			<u-parse :content="detail.body"></u-parse>
		</view>
	</view>
</template>

<script>
	export default {
		data(){
			return{
				id:'',
				detail:{}
			}
		},
		onLoad(e) {
			if(e.id){
				console.log(e.id)
				this.id = e.id 
				this.getSchoolDetail(e.id)
			}
		},
		methods:{
			async getSchoolDetail(id){
				let res = await this.$api.post(global.apiUrls.postShoolInfo, {
					id:id
				}, {
					token: true
				})
				console.log(res.data)
				this.detail = res.data.data

			}
		}
	}
</script>

<style lang="scss" scoped>
	.mb-2{
		margin-bottom: 20rpx;
	}
	.title{
		font-size: 30rpx;
		margin-bottom: 20rpx;
	}
	.news-info-view{
		padding: 30rpx;
		background-color: #ffffff;
		border-radius: 20rpx;
	}
</style>